package com.zzg.util;

import java.util.Date;
import java.util.Random;
import java.util.UUID;

/**
 * 产生UUID随机字符串工具类
 */
public final class UuidUtil {
	private UuidUtil(){}
	public static String getUuid(){
		Date date=new Date();
		String time = date.getTime()+"";
		Random random=new Random();
		int i = random.nextInt(9);
		int i1 = random.nextInt(9);
		time+=i+i1;

		return time.substring(6,time.length());
	}

	public static void main(String[] args) {
		System.out.println(UuidUtil.getUuid());
	}
	public static String getUuidS(){
		return UUID.randomUUID().toString().replace("-","");
	}




}
